//
//  CommunityHeadCell.m
//  Qyer
//
//  Created by dllo on 15/10/19.
//  Copyright (c) 2015年 GF. All rights reserved.
//

#import "CommunityHeadCell.h"

@implementation CommunityHeadCell
- (instancetype)initWithFrame:(CGRect)frame {
    self = [super initWithFrame:frame];
    if (self) {
        self.backgroundColor = WHITE_COLOR;
        _picView = [[UIImageView alloc]initWithFrame:CRM(20 * WIDTH, 0, 55 * WIDTH, 55 * WIDTH)];
        
        [self.contentView addSubview:_picView];
        
        _title = [[UILabel alloc] initWithFrame:CRM(80 * WIDTH, 15 * HEIGHT, self.frame.size.width - 90 * WIDTH, 40 * HEIGHT)];
        [self.contentView addSubview:_title];
        
        _countLabel = [[UILabel alloc] initWithFrame:CRM(15 * WIDTH, 60 * HEIGHT, self.frame.size.width - 10 * WIDTH, 30 * HEIGHT)];
        _countLabel.font = [UIFont systemFontOfSize:14.];
        _countLabel.textColor = [UIColor lightGrayColor];
        [self.contentView addSubview:_countLabel];
    }
    return self;
}
- (void)setCellWithArr:(NSArray *)arr index:(NSInteger)index {
    
    _title.text = [arr objectAtIndex:index];
    _picView.image = [UIImage imageNamed:[arr objectAtIndex:index + 2]];
    _countLabel.text = [arr objectAtIndex:index + 4];
}
@end
